<?php
require_once(ROOT_ADMIN_MODELS.DS.'Models_Index.php');
require_once(ROOT_ADMIN_CONTROLLERS.DS.'BaseController.php');
class Admin_IndexController extends BaseController {
	
	public function preDispatch()
	{
		parent::preDispatch();	
		if(!$this->hasPrivilege())
			$this->_redirect ("/admin/error/permission");
	}
	
	
	public function indexAction(){
		$baseurl=$this->_request->getbaseurl();
		
		$this->view ->headTitle("TRang chu");
		$this->view->headLink()->appendStylesheet($baseurl."/public/css/test.css");
		$muser=new Model_Index();
		$data=$muser->listall();
		echo "<pre>";
		print_r($data);
		echo "</pre>";
		 
		
				
	
	}
	public function editAction(){
	
		
	
	}
	
}